bLIP-56: Pluggable Channel Factories. #56
+982
−7
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Channel factories are a way of scaling Bitcoin by hosting offchain channels, not directly onchain, but in another offchain mechanism. The hosting mechanism is called a channel factory. The channel factory can change the funding amounts of channels inside the factory, without any onchain transactions.
This pluggable channel factory protocol is a proposal by which base node software can handle channel state, while letting external code handle state of the channel factory. As far as the node software is concerned, the channel is a "0-conf" channel whose funding transaction never seems to confirm, even though the state is actually backed by an offchain mechanism that ensures that the channel can be unilaterally closed in the worst-case scenario.
When the channel factory wants to change the funding amounts of hosted channels, the node software acts as if a splice operation is being performed, which changes the funding amount (or not changes it, if it is other channels in the same factory that are changed but not this one). When the channel factory offchain mechanism has settled to a new state, it is as if a splice transaction was successfully deeply confirmed.